package com.qingyouchuxing.mall.biz.service;

import com.mybatisflex.core.service.IService;
import com.qingyouchuxing.mall.biz.domain.dto.MallMailAddressDTO;
import com.qingyouchuxing.mall.biz.domain.entity.MallMailAddress;
import com.qingyouchuxing.mall.biz.domain.vo.MallMailAddressVO;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Transactional
public interface IMallMailAddressService extends IService<MallMailAddress> {
    /**
     * 根据寄件地址ID查询商品寄件地址
     *
     * @param id
     * @return
     */
    MallMailAddressVO selectMailAddressById(Long fkTenantId, Long id);

    /**
     * 查询商品寄件地址
     *
     * @param id
     * @return
     */
    List<MallMailAddressVO> selectMailAddressByIdList(Long fkTenantId, Long id);

    /**
     * 添加商品寄件地址
     *
     * @param dto
     * @return
     */
    boolean addMailAddress(MallMailAddressDTO dto);

    /**
     * 删除商品寄件地址
     *
     * @param id 寄件地址ID
     * @return
     */
    boolean removeMailAddressById(Long fkTenantId, Long id);

    /**
     * 修改商品寄件地址
     *
     * @param dto
     * @return
     */
    boolean updateMailAddress(MallMailAddressDTO dto);


}
